<!DOCTYPE html>
<html lang="en">
  <head>
    <title>Type Aliases  Reference</title>
    <link rel="stylesheet" type="text/css" href="css/jazzy.css" />
    <link rel="stylesheet" type="text/css" href="css/highlight.css" />
    <meta charset="utf-8">
    <script src="js/jquery.min.js" defer></script>
    <script src="js/jazzy.js" defer></script>
    
    <script src="js/lunr.min.js" defer></script>
    <script src="js/typeahead.jquery.js" defer></script>
    <script src="js/jazzy.search.js" defer></script>
  </head>
  <body>

    <a name="//apple_ref/swift/Section/Type Aliases" class="dashAnchor"></a>

    <a title="Type Aliases  Reference"></a>

    <header class="header">
      <p class="header-col header-col--primary">
        <a class="header-link" href="index.html">
          Kitura Docs
        </a>
         (99% documented)
      </p>
    
      <p class="header-col--secondary">
        <form role="search" action="search.json">
          <input type="text" placeholder="Search documentation" data-typeahead>
        </form>
      </p>
    
        <p class="header-col header-col--secondary">
          <a class="header-link" href="https://github.com/Kitura/Kitura/">
            <img class="header-icon" src="img/gh.png"/>
            View on GitHub
          </a>
        </p>
    
    </header>

    <p class="breadcrumbs">
      <a class="breadcrumb" href="index.html">Kitura Reference</a>
      <img class="carat" src="img/carat.png" />
      Type Aliases  Reference
    </p>

    <div class="content-wrapper">
      <nav class="navigation">
        <ul class="nav-groups">
          <li class="nav-group-name">
            <a class="nav-group-name-link" href="Classes.html">Classes</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Classes/BodyParser.html">BodyParser</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Classes/BodyParserMultiValue.html">BodyParserMultiValue</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Classes/ContentType.html">ContentType</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Classes/Kitura.html">Kitura</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Classes/Router.html">Router</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Classes/RouterMiddlewareGenerator.html">RouterMiddlewareGenerator</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Classes/RouterRequest.html">RouterRequest</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Classes/RouterResponse.html">RouterResponse</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Classes/StaticFileServer.html">StaticFileServer</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Classes/StaticFileServer/CacheOptions.html">– CacheOptions</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Classes/StaticFileServer/Options.html">– Options</a>
              </li>
            </ul>
          </li>
          <li class="nav-group-name">
            <a class="nav-group-name-link" href="Enums.html">Enumerations</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Enums/JSONPError.html">JSONPError</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Enums/LinkParameter.html">LinkParameter</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Enums/ParsedBody.html">ParsedBody</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Enums/RouterMethod.html">RouterMethod</a>
              </li>
            </ul>
          </li>
          <li class="nav-group-name">
            <a class="nav-group-name-link" href="Extensions.html">Extensions</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Extensions/DecodingError.html">DecodingError</a>
              </li>
            </ul>
          </li>
          <li class="nav-group-name">
            <a class="nav-group-name-link" href="Protocols.html">Protocols</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Protocols/ResponseHeadersSetter.html">ResponseHeadersSetter</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Protocols/RouterMiddleware.html">RouterMiddleware</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Protocols/TypeSafeMiddleware.html">TypeSafeMiddleware</a>
              </li>
            </ul>
          </li>
          <li class="nav-group-name">
            <a class="nav-group-name-link" href="Structs.html">Structures</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Structs/AdditionalCookieAttribute.html">AdditionalCookieAttribute</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Structs/CodableHelpers.html">CodableHelpers</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Structs/HTTPVersion.html">HTTPVersion</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Structs/Headers.html">Headers</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Structs/MediaType.html">MediaType</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Structs/MediaType/TopLevelType.html">– TopLevelType</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Structs/Part.html">Part</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Structs/Part/HeaderType.html">– HeaderType</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Structs/SSLConfig.html">SSLConfig</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Structs/SwaggerDocument.html">SwaggerDocument</a>
              </li>
            </ul>
          </li>
          <li class="nav-group-name">
            <a class="nav-group-name-link" href="Typealiases.html">Type Aliases</a>
            <ul class="nav-group-tasks">
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Typealiases.html#/s:6Kitura14HTTPStatusCodea">HTTPStatusCode</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Typealiases.html#/s:6Kitura16LifecycleHandlera">LifecycleHandler</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Typealiases.html#/s:6Kitura12RequestErrora">RequestError</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Typealiases.html#/s:6Kitura13RouterHandlera">RouterHandler</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Typealiases.html#/s:6Kitura22RouterParameterHandlera">RouterParameterHandler</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Typealiases.html#/s:6Kitura13ServerOptionsa">ServerOptions</a>
              </li>
              <li class="nav-group-task">
                <a class="nav-group-task-link" href="Typealiases.html#/s:6Kitura17WrittenDataFiltera">WrittenDataFilter</a>
              </li>
            </ul>
          </li>
        </ul>
      </nav>
      <article class="main-content">

        <section class="section">
          <div class="section-content top-matter">
            <h1>Type Aliases</h1>
            <p>The following type aliases are available globally.</p>

          </div>
        </section>

        <section class="section">
          <div class="section-content">
            <div class="task-group">
              <ul class="item-container">
                <li class="item">
                  <div>
                    <code>
                    <a name="/s:6Kitura12RequestErrora"></a>
                    <a name="//apple_ref/swift/Alias/RequestError" class="dashAnchor"></a>
                    <a class="token" href="#/s:6Kitura12RequestErrora">RequestError</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>Bridge <a href="https://ibm-swift.github.io/KituraContracts/Structs/RequestError.html">RequestError</a>
from <a href="https://ibm-swift.github.io/KituraContracts">KituraContracts</a> so that you only need to import
<code><a href="Classes/Kitura.html">Kitura</a></code> to access it.</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Swift</p>
                          <pre class="highlight swift"><code><span class="kd">public</span> <span class="kd">typealias</span> <span class="kt">RequestError</span> <span class="o">=</span> <span class="kt">KituraContracts</span><span class="o">.</span><span class="kt">RequestError</span></code></pre>

                        </div>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/s:6Kitura14HTTPStatusCodea"></a>
                    <a name="//apple_ref/swift/Alias/HTTPStatusCode" class="dashAnchor"></a>
                    <a class="token" href="#/s:6Kitura14HTTPStatusCodea">HTTPStatusCode</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>Bridge <a href="http://ibm-swift.github.io/Kitura-net/Enums/HTTPStatusCode.html">HTTPStatusCode</a>
from <a href="http://ibm-swift.github.io/Kitura-net">KituraNet</a> so that you only need to import
<code><a href="Classes/Kitura.html">Kitura</a></code> to access it.</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Swift</p>
                          <pre class="highlight swift"><code><span class="kd">public</span> <span class="kd">typealias</span> <span class="kt">HTTPStatusCode</span> <span class="o">=</span> <span class="kt">KituraNet</span><span class="o">.</span><span class="kt">HTTPStatusCode</span></code></pre>

                        </div>
                      </div>
                    </section>
                  </div>
                </li>
              </ul>
            </div>
            <div class="task-group">
              <div class="task-name-container">
                <a name="/ServerOptions"></a>
                <a name="//apple_ref/swift/Section/ServerOptions" class="dashAnchor"></a>
                <div class="section-name-container">
                  <a class="section-name-link" href="#/ServerOptions"></a>
                  <h3 class="section-name"><p>ServerOptions</p>
</h3>
                </div>
              </div>
              <ul class="item-container">
                <li class="item">
                  <div>
                    <code>
                    <a name="/s:6Kitura13ServerOptionsa"></a>
                    <a name="//apple_ref/swift/Alias/ServerOptions" class="dashAnchor"></a>
                    <a class="token" href="#/s:6Kitura13ServerOptionsa">ServerOptions</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>Bridge <a href="http://ibm-swift.github.io/Kitura-net/Structs/ServerOptions.html">ServerOptions</a> from <a href="http://ibm-swift.github.io/Kitura-net">KituraNet</a> so that you only need to import <code><a href="Classes/Kitura.html">Kitura</a></code> to access it.</p>

<p>ServerOptions allows customization of default connection policies, including:</p>

<ul>
<li><code>requestSizeLimit</code>: Defines the maximum size of an incoming request body, in bytes. If requests are received that are larger than this limit, they will be rejected and the connection will be closed. A value of <code>nil</code> means no limit.</li>
<li><code>connectionLimit</code>: Defines the maximum number of concurrent connections that a server should accept. Clients attempting to connect when this limit has been reached will be rejected. A value of <code>nil</code> means no limit.</li>
</ul>

<p>The server can optionally respond to the client with a message in either of these cases. This message can be customized by defining <code>requestSizeResponseGenerator</code> and <code>connectionResponseGenerator</code>.</p>

<p>Example usage:</p>
<pre class="highlight swift"><code><span class="k">let</span> <span class="nv">port</span> <span class="o">=</span> <span class="mi">8080</span>
<span class="k">let</span> <span class="nv">router</span> <span class="o">=</span> <span class="kt">Router</span><span class="p">()</span>
<span class="k">let</span> <span class="nv">connectionResponse</span><span class="p">:</span> <span class="p">(</span><span class="kt">Int</span><span class="p">,</span> <span class="kt">String</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="p">(</span><span class="kt">HTTPStatusCode</span><span class="p">,</span> <span class="kt">String</span><span class="p">)?</span> <span class="o">=</span> <span class="p">{</span> <span class="p">(</span><span class="n">limit</span><span class="p">,</span> <span class="n">client</span><span class="p">)</span> <span class="k">in</span>
    <span class="kt">Log</span><span class="o">.</span><span class="nf">debug</span><span class="p">(</span><span class="s">"Rejecting request from </span><span class="se">\(</span><span class="n">client</span><span class="se">)</span><span class="s">: Connection limit </span><span class="se">\(</span><span class="n">limit</span><span class="se">)</span><span class="s"> reached"</span><span class="p">)</span>
    <span class="nf">return</span> <span class="p">(</span><span class="o">.</span><span class="n">serviceUnavailable</span><span class="p">,</span> <span class="s">"Service busy - please try again later.</span><span class="se">\r\n</span><span class="s">"</span><span class="p">)</span>
<span class="p">}</span>
<span class="k">let</span> <span class="nv">serverOptions</span> <span class="o">=</span> <span class="kt">ServerOptions</span><span class="p">(</span><span class="nv">requestSizeLimit</span><span class="p">:</span> <span class="mi">1000</span><span class="p">,</span> <span class="nv">connectionLimit</span><span class="p">:</span> <span class="mi">10</span><span class="p">,</span> <span class="nv">connectionResponseGenerator</span><span class="p">:</span> <span class="n">connectionResponse</span><span class="p">)</span>
<span class="kt">Kitura</span><span class="o">.</span><span class="nf">addHTTPServer</span><span class="p">(</span><span class="nv">onPort</span><span class="p">:</span> <span class="n">port</span><span class="p">,</span> <span class="nv">with</span><span class="p">:</span> <span class="n">router</span><span class="p">,</span> <span class="nv">options</span><span class="p">:</span> <span class="n">serverOptions</span><span class="p">)</span>
</code></pre>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Swift</p>
                          <pre class="highlight swift"><code><span class="kd">public</span> <span class="kd">typealias</span> <span class="kt">ServerOptions</span> <span class="o">=</span> <span class="kt">KituraNet</span><span class="o">.</span><span class="kt">ServerOptions</span></code></pre>

                        </div>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/s:6Kitura13RouterHandlera"></a>
                    <a name="//apple_ref/swift/Alias/RouterHandler" class="dashAnchor"></a>
                    <a class="token" href="#/s:6Kitura13RouterHandlera">RouterHandler</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>The definition of the closure type that is used by the <code><a href="Classes/Router.html">Router</a></code> class
when routing HTTP requests to closure.</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Swift</p>
                          <pre class="highlight swift"><code><span class="kd">public</span> <span class="kd">typealias</span> <span class="kt">RouterHandler</span> <span class="o">=</span> <span class="p">(</span><span class="kt"><a href="Classes/RouterRequest.html">RouterRequest</a></span><span class="p">,</span> <span class="kt"><a href="Classes/RouterResponse.html">RouterResponse</a></span><span class="p">,</span> <span class="kd">@escaping</span> <span class="p">()</span> <span class="o">-&gt;</span> <span class="kt">Void</span><span class="p">)</span> <span class="k">throws</span> <span class="o">-&gt;</span> <span class="kt">Void</span></code></pre>

                        </div>
                      </div>
                      <div>
                        <h4>Parameters</h4>
                        <table class="graybox">
                          <tbody>
                            <tr>
                              <td>
                                <code>
                                <em>request</em>
                                </code>
                              </td>
                              <td>
                                <div>
                                  <p>The <code><a href="Classes/RouterRequest.html">RouterRequest</a></code> object used to work with the incoming
                HTTP request.</p>
                                </div>
                              </td>
                            </tr>
                            <tr>
                              <td>
                                <code>
                                <em>response</em>
                                </code>
                              </td>
                              <td>
                                <div>
                                  <p>The <code><a href="Classes/RouterResponse.html">RouterResponse</a></code> object used to respond to the
                HTTP request.</p>
                                </div>
                              </td>
                            </tr>
                            <tr>
                              <td>
                                <code>
                                <em>next</em>
                                </code>
                              </td>
                              <td>
                                <div>
                                  <p>The closure called to invoke the next handler or middleware
                associated with the request.</p>
                                </div>
                              </td>
                            </tr>
                          </tbody>
                        </table>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/s:6Kitura22RouterParameterHandlera"></a>
                    <a name="//apple_ref/swift/Alias/RouterParameterHandler" class="dashAnchor"></a>
                    <a class="token" href="#/s:6Kitura22RouterParameterHandlera">RouterParameterHandler</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>A <a href="https://developer.apple.com/library/content/documentation/Swift/Conceptual/Swift_Programming_Language/Declarations.html#//apple_ref/doc/uid/TP40014097-CH34-ID361">type alias</a> declaration to describe a handler for named parameters when using <code><a href="Classes/Router.html#/s:6Kitura6RouterC9parameter_7handlerACSS_yAA0B7RequestC_AA0B8ResponseCSSyyctKcdtF">Router.parameter(...)</a></code>. The example below shows two ways to use it, both as a function named <code>handler</code> to handle the &ldquo;id&rdquo; parameter and as a closure to handle the &ldquo;name&rdquo; parameter.</p>
<h3 id='usage-example' class='heading'>Usage Example:</h3>
<pre class="highlight swift"><code><span class="k">let</span> <span class="nv">router</span> <span class="o">=</span> <span class="kt">Router</span><span class="p">()</span>
<span class="kd">func</span> <span class="nf">handler</span><span class="p">(</span><span class="nv">request</span><span class="p">:</span> <span class="kt">RouterRequest</span><span class="p">,</span> <span class="nv">response</span><span class="p">:</span> <span class="kt">RouterResponse</span><span class="p">,</span> <span class="nv">param</span><span class="p">:</span> <span class="kt">String</span><span class="p">,</span> <span class="nv">next</span><span class="p">:</span> <span class="kd">@escaping</span> <span class="p">()</span> <span class="o">-&gt;</span> <span class="kt">Void</span><span class="p">)</span> <span class="k">throws</span> <span class="o">-&gt;</span> <span class="kt">Void</span> <span class="p">{</span>
    <span class="c1">//Code to handle id parameter here</span>
    <span class="nf">next</span><span class="p">()</span>
<span class="p">}</span>
<span class="n">router</span><span class="o">.</span><span class="nf">parameter</span><span class="p">(</span><span class="s">"id"</span><span class="p">,</span> <span class="nv">handler</span><span class="p">:</span> <span class="n">handler</span><span class="p">)</span>

<span class="n">router</span><span class="o">.</span><span class="nf">parameter</span><span class="p">(</span><span class="s">"name"</span><span class="p">)</span> <span class="p">{</span> <span class="n">request</span><span class="p">,</span> <span class="n">response</span><span class="p">,</span> <span class="n">param</span><span class="p">,</span> <span class="n">next</span> <span class="k">in</span>
    <span class="c1">//Code to handle name parameter here</span>
    <span class="nf">next</span><span class="p">()</span>
<span class="p">}</span>
<span class="n">router</span><span class="o">.</span><span class="nf">get</span><span class="p">(</span><span class="s">"/item/:id"</span><span class="p">)</span> <span class="p">{</span> <span class="n">request</span><span class="p">,</span> <span class="n">response</span><span class="p">,</span> <span class="n">next</span> <span class="k">in</span>
    <span class="c1">//This will be reached after the id parameter is handled by `handler`</span>
<span class="p">}</span>
<span class="n">router</span><span class="o">.</span><span class="nf">get</span><span class="p">(</span><span class="s">"/user/:name"</span><span class="p">)</span> <span class="p">{</span> <span class="n">request</span><span class="p">,</span> <span class="n">response</span><span class="p">,</span> <span class="n">next</span> <span class="k">in</span>
    <span class="c1">//This will be reached after the name parameter is handled by the closure above</span>
<span class="p">}</span>
</code></pre>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Swift</p>
                          <pre class="highlight swift"><code><span class="kd">public</span> <span class="kd">typealias</span> <span class="kt">RouterParameterHandler</span> <span class="o">=</span> <span class="p">(</span><span class="kt"><a href="Classes/RouterRequest.html">RouterRequest</a></span><span class="p">,</span> <span class="kt"><a href="Classes/RouterResponse.html">RouterResponse</a></span><span class="p">,</span> <span class="kt">String</span><span class="p">,</span> <span class="kd">@escaping</span> <span class="p">()</span> <span class="o">-&gt;</span> <span class="kt">Void</span><span class="p">)</span> <span class="k">throws</span> <span class="o">-&gt;</span> <span class="kt">Void</span></code></pre>

                        </div>
                      </div>
                      <div>
                        <h4>Parameters</h4>
                        <table class="graybox">
                          <tbody>
                            <tr>
                              <td>
                                <code>
                                <em>request</em>
                                </code>
                              </td>
                              <td>
                                <div>
                                  <p>The <code><a href="Classes/RouterRequest.html">RouterRequest</a></code> object used to work with the incoming
                HTTP request.</p>
                                </div>
                              </td>
                            </tr>
                            <tr>
                              <td>
                                <code>
                                <em>response</em>
                                </code>
                              </td>
                              <td>
                                <div>
                                  <p>The <code><a href="Classes/RouterResponse.html">RouterResponse</a></code> object used to respond to the
                HTTP request.</p>
                                </div>
                              </td>
                            </tr>
                            <tr>
                              <td>
                                <code>
                                <em>param</em>
                                </code>
                              </td>
                              <td>
                                <div>
                                  <p>The named parameter to be handled.</p>
                                </div>
                              </td>
                            </tr>
                            <tr>
                              <td>
                                <code>
                                <em>next</em>
                                </code>
                              </td>
                              <td>
                                <div>
                                  <p>The closure called to invoke the next handler or middleware
                associated with the request.</p>
                                </div>
                              </td>
                            </tr>
                          </tbody>
                        </table>
                      </div>
                    </section>
                  </div>
                </li>
              </ul>
            </div>
            <div class="task-group">
              <div class="task-name-container">
                <a name="/RouterResponse"></a>
                <a name="//apple_ref/swift/Section/RouterResponse" class="dashAnchor"></a>
                <div class="section-name-container">
                  <a class="section-name-link" href="#/RouterResponse"></a>
                  <h3 class="section-name"><p>RouterResponse</p>
</h3>
                </div>
              </div>
              <ul class="item-container">
                <li class="item">
                  <div>
                    <code>
                    <a name="/s:6Kitura16LifecycleHandlera"></a>
                    <a name="//apple_ref/swift/Alias/LifecycleHandler" class="dashAnchor"></a>
                    <a class="token" href="#/s:6Kitura16LifecycleHandlera">LifecycleHandler</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>Type alias for &ldquo;Before flush&rdquo; (i.e. before headers and body are written) lifecycle handler.</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Swift</p>
                          <pre class="highlight swift"><code><span class="kd">public</span> <span class="kd">typealias</span> <span class="kt">LifecycleHandler</span> <span class="o">=</span> <span class="p">()</span> <span class="o">-&gt;</span> <span class="kt">Void</span></code></pre>

                        </div>
                      </div>
                    </section>
                  </div>
                </li>
                <li class="item">
                  <div>
                    <code>
                    <a name="/s:6Kitura17WrittenDataFiltera"></a>
                    <a name="//apple_ref/swift/Alias/WrittenDataFilter" class="dashAnchor"></a>
                    <a class="token" href="#/s:6Kitura17WrittenDataFiltera">WrittenDataFilter</a>
                    </code>
                  </div>
                  <div class="height-container">
                    <div class="pointer-container"></div>
                    <section class="section">
                      <div class="pointer"></div>
                      <div class="abstract">
                        <p>Type alias for written data filter, i.e. pre-write lifecycle handler.</p>

                      </div>
                      <div class="declaration">
                        <h4>Declaration</h4>
                        <div class="language">
                          <p class="aside-title">Swift</p>
                          <pre class="highlight swift"><code><span class="kd">public</span> <span class="kd">typealias</span> <span class="kt">WrittenDataFilter</span> <span class="o">=</span> <span class="p">(</span><span class="kt">Data</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="kt">Data</span></code></pre>

                        </div>
                      </div>
                    </section>
                  </div>
                </li>
              </ul>
            </div>
          </div>
        </section>

      </article>
    </div>
    <section class="footer">
      <p>&copy; 2021 <a class="link" href="" target="_blank" rel="external">IBM &amp; Kitura project authors</a>. All rights reserved. (Last updated: 2021-01-25)</p>
      <p>Generated by <a class="link" href="https://github.com/realm/jazzy" target="_blank" rel="external">jazzy ♪♫ v0.13.6</a>, a <a class="link" href="https://realm.io" target="_blank" rel="external">Realm</a> project.</p>
    </section>
  </body>
</div>
</html>
